Skip to content

fix(ci): harden publish-docs workflow security and update actions - #20

Closed
jmeridth wants to merge 6 commits into
EpicGames:mainfrom
jmeridth:fix/harden-publish-docs-workflow
Closed

fix(ci): harden publish-docs workflow security and update actions#20
jmeridth wants to merge 6 commits into
EpicGames:mainfrom
jmeridth:fix/harden-publish-docs-workflow

Conversation

@jmeridth

@jmeridth jmeridth commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Similar to #7 but use full SHAs for actions

What/Why

Reduce blast radius of a compromised action by moving permissions to job level with least-privilege grants, disabling credential persistence on checkout, and pinning all actions to SHA at their latest versions.

Proof it works

actionlint passes clean. Workflow is push-to-main only so will be validated on merge.

Risk + AI role

Low -- workflow-only change, no application code affected. AI-assisted (Claude Opus 4.6).

Review focus

Verify the major version bumps (checkout v4->v6, setup-uv v5->v8, configure-pages v5->v6, upload-pages-artifact v3->v5, deploy-pages v4->v5) don't introduce breaking changes for this usage.

What/Why

Reduce blast radius of a compromised action by moving permissions to
job level with least-privilege grants, disabling credential persistence
on checkout, and pinning all actions to SHA at their latest versions.

Proof it works

actionlint passes clean. Workflow is push-to-main only so will be
validated on merge.

Risk + AI role

Low -- workflow-only change, no application code affected. All changes
AI-generated (Claude Opus 4.6, claude-opus-4-6), human-reviewed.

Review focus

Verify the major version bumps (checkout v4->v6, setup-uv v5->v8,
configure-pages v5->v6, upload-pages-artifact v3->v5,
deploy-pages v4->v5) don't introduce breaking changes for this usage.

Signed-off-by: jmeridth <jmeridth@gmail.com>
@jmeridth
jmeridth marked this pull request as ready for review June 18, 2026 03:51
@ragnarula
ragnarula requested review from dubuc and duncangrist June 18, 2026 12:08
@duncangrist

Copy link
Copy Markdown
Contributor

This looks like a good hardening practice, thank you.

Can you test it end-to-end against your fork to ensure the changes actually work? Mention you've done that in this PR and we'll be happy to approve it.

jmeridth added 2 commits June 18, 2026 07:38
What/Why

Reduce blast radius of a compromised action by moving permissions to
job level with least-privilege grants, disabling credential persistence
on checkout, and pinning all actions to SHA at their latest versions.

Proof it works

actionlint passes clean. Workflow is push-to-main only so will be
validated on merge.

Risk + AI role

Low -- workflow-only change, no application code affected. All changes
AI-generated (Claude Opus 4.6, claude-opus-4-6), human-reviewed.

Review focus

Verify the major version bumps (checkout v4->v6, setup-uv v5->v8,
configure-pages v5->v6, upload-pages-artifact v3->v5,
deploy-pages v4->v5) don't introduce breaking changes for this usage.

Signed-off-by: jmeridth <jmeridth@gmail.com>
Signed-off-by: jmeridth <jmeridth@gmail.com>
@jmeridth

Copy link
Copy Markdown
Contributor Author

This looks like a good hardening practice, thank you.

Can you test it end-to-end against your fork to ensure the changes actually work? Mention you've done that in this PR and we'll be happy to approve it.

@duncangrist As noted above, this change only works after merge to main (A GitHub Actions "feature"). Still able to test in my fork as requested.

I cherry-picked the commit to my fork's main branch and manually ran the workflow here. It succeeded. Had to manually run because it was the first time on the main branch.

I updated docs/README.md file and pushed to main to ensure the workflow triggered automatically when push to main in docs folder occurs. Succeeded also.

Resulting GitHub Pages Docs

Screenshot from first run and deploy

Screenshot 2026-06-18 at 08 12 10

Screenshot with my test content change - run and deploy

Screenshot 2026-06-18 at 08 13 04

@duncangrist duncangrist left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes are approved, but you won't be able to merge yourself. We're not ready with the contributor merge workflow just yet, but once we are we'll get this one integrated.

Thanks again.

jmeridth added 2 commits June 18, 2026 17:28
Keep SHA-pinned actions/deploy-pages@v5.0.0 over upstream's unpinned
v4 tag reference -- newer version and pinned to SHA for security.

Signed-off-by: jmeridth <jmeridth@gmail.com>
Comment thread docs/README.md Outdated
@jmeridth
jmeridth force-pushed the fix/harden-publish-docs-workflow branch from 9bd2843 to b89fca2 Compare July 11, 2026 16:32
Removed placeholder text from the README file.

Signed-off-by: Jason Meridth <jmeridth@gmail.com>
@jmeridth
jmeridth force-pushed the fix/harden-publish-docs-workflow branch from b89fca2 to 84d15eb Compare July 11, 2026 16:34
@concernedrat concernedrat added the ready-to-import Approved by Epic staff for import into Lore label Jul 13, 2026
@epic-lore-bot epic-lore-bot Bot added imported Imported into Lore for internal review and removed ready-to-import Approved by Epic staff for import into Lore labels Jul 13, 2026
@epic-lore-bot

epic-lore-bot Bot commented Jul 13, 2026

Copy link
Copy Markdown

Imported as Lore CR-203.

epic-lore-bot Bot pushed a commit that referenced this pull request Jul 14, 2026
Similar to #7 but use full SHAs for actions

## What/Why

Reduce blast radius of a compromised action by moving permissions to job level with least-privilege grants, disabling credential persistence on checkout, and pinning all actions to SHA at their latest versions.

## Proof it works

actionlint passes clean. Workflow is push-to-main only so will be validated on merge.

## Risk + AI role

Low -- workflow-only change, no application code affected. AI-assisted (Claude Opus 4.6).

## Review focus

Verify the major version bumps (checkout v4->v6, setup-uv v5->v8, configure-pages v5->v6, upload-pages-artifact v3->v5, deploy-pages v4->v5) don't introduce breaking changes for this usage.

```
Imported-PR: #20
Imported-From: 84d15eb
Imported-Base: f3d23d4
Imported-Merge: bf38ee9
Imported-Author: Jason Meridth (jmeridth)
Signed-off-by: Jason Meridth <jmeridth@gmail.com>
GH-URL: #20
```

Lore-RevId: 304
Lore-Signature: 916e92b828678bca5fd8cedf22cdbcd1a5c3fc76d3d128abcbd03daf449161c6
@epic-lore-bot

epic-lore-bot Bot commented Jul 14, 2026

Copy link
Copy Markdown

Closed by mirrored commit d0a32e1.

@epic-lore-bot epic-lore-bot Bot closed this Jul 14, 2026
@epic-lore-bot epic-lore-bot Bot added the merged Merged into Lore codebase label Jul 14, 2026
@duncangrist

Copy link
Copy Markdown
Contributor

Congratulations @jmeridth - you're the first external collaborator to have their contribution merged into the Lore codebase!

@jmeridth
jmeridth deleted the fix/harden-publish-docs-workflow branch July 21, 2026 15:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

imported Imported into Lore for internal review merged Merged into Lore codebase

Development

Successfully merging this pull request may close these issues.

4 participants